{template 'common/header-gw'}
<ol class="breadcrumb">
	<li><a href="./?refresh"><i class="fa fa-home"></i></a></li>
	<li class=""><a href="{url 'system/welcome'}">云服务</a></li>
	<li class="active">云服务诊断</li>
</ol>
<div class="main">
	<form action="" method="post" class="form-horizontal form" role="form" onsubmit="return confirm('如果您的系统没有发生云服务链接异常, 请不要使用重置功能.');">
		<h5 class="page-header">云服务状态诊断</h5>
		<div class="form-group">
			<label class="col-xs-12 col-sm-2 col-md-2 col-lg-1 control-label">站点URL</label>
			<div class="col-sm-10">
				<p class="form-control-static">{$_W['siteroot']}</p>
			</div>
		</div>
		<div class="form-group">
			<label class="col-xs-12 col-sm-2 col-md-2 col-lg-1 control-label">站点ID</label>
			<div class="col-sm-10">
				<p class="form-control-static">{$_W['setting']['site']['key']}</p>
			</div>
		</div>
		<div class="form-group">
			<label class="col-xs-12 col-sm-2 col-md-2 col-lg-1 control-label">通信密钥</label>
			<div class="col-sm-10">
				<p class="form-control-static">{php echo substr($_W['setting']['site']['token'], 0, 5) . '*****' . substr($_W['setting']['site']['token'], -5, 5);}</p>
				<div class="help-block">
					<a href="javascript:;" id="look">查看全部</a>&nbsp;&nbsp;
					<input type="hidden" value="{$_W['setting']['site']['token']}" id="token" />
				</div>
				<div class="help-block">请查看您的站点ID和通信密钥, 需要保证与<a href="{php echo url('cloud/profile');}">云服务平台记录</a>的值一致, 否则不能正常使用云平台的各项服务. </div>
			</div>
		</div>
		<div class="form-group">
			<label class="col-xs-12 col-sm-2 col-md-2 col-lg-1 control-label">系统版本</label>
			<div class="col-sm-10">
				<p class="form-control-static">WeEngine{php echo IMS_VERSION}{php echo IMS_FAMILY} (Release {php echo IMS_RELEASE_DATE})</p>
			</div>
		</div>
		<div class="form-group">
			<div class="col-sm-offset-2 col-md-offset-2 col-lg-offset-1 col-xs-12 col-sm-10 col-md-10 col-lg-11">
				<input type="submit" name="submit" value="重置站点ID和通信密钥" class="btn btn-primary" />
				<input type="hidden" name="token" value="{$_W['token']}" />
				<div class="help-block">如果您的站点ID和通信密钥与您绑定的站点信息中的记录不一致, 或访问云服务失败并多次重试后无效时. 请点击重置按钮, 重新注册您的站点信息(如果需要使用相同的微擎论坛账号绑定, 需要先在云服务后台中解除绑定) </div>
			</div>
		</div>
	</form>
</div>
<script>
	require(['jquery', 'util'], function($, u){
		$('#look').click(function(){
			u.message('Token:' + $('#token').val(), '', 'info');
		})
	});
</script>
{template 'common/footer-gw'}
